package main
import "fmt"

type stu struct{
	name string
	age int
}

type student struct{
	stu
	sex byte
}

func main(){
	var a student = student{ stu{"Ruige", 22}, 'G'}
	fmt.Println("a = ", a)
	
	fmt.Printf("姓名：%s\n年龄：%d\n性别：%c\n", a.name, a.age, a.sex)
	
	b := student{ stu{"瑞哥", 22}, 'G' }
	fmt.Printf("姓名：%s\n年龄：%d\n性别：%c\n", b.name, b.age, b.sex)
	
	fmt.Printf("b = %+v\n", b)
}
